package net.neptech.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import net.neptech.model.sys.Dept;
import net.neptech.vo.StaffVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface DeptMapper extends BaseMapper<Dept> {

    List<Dept> selectDeptList(Dept dept);

    Dept selectDeptById(Long deptId);

    void updateDept(Dept dept);

    int hasChildByDeptId(Long deptId);

    Page<Dept> getDeptPage(@Param("dept") Dept dept, @Param("page") Page<StaffVo> page);
}
